//
//  NewPayFinishViewController.m
//  wangzhe
//
//  Created by 李 佳伟 on 2018/3/26.
//  Copyright © 2018年 李 佳伟. All rights reserved.
//

#import "NewPayFinishViewController.h"
#import "JTCSM.h"
@interface NewPayFinishViewController ()
@property (nonatomic,strong) UILabel *statusLabel;
@property (nonatomic,strong) UILabel *moneyLabel;
@end

@implementation NewPayFinishViewController

- (void)gotBack{
    [self.navigationController popViewControllerAnimated:YES];
}
- (void)viewWillAppear:(BOOL)animated{
    [super viewWillAppear:animated];
    self.navigationController.navigationBar.hidden = YES;
    
}
- (void)viewDidLoad {
    [super viewDidLoad];
    [df isRemoveTarbar:YES];
    self.navigationController.navigationBar.hidden = YES;
    self.view.backgroundColor =[UIColor whiteColor];
    leftBarButtonItems_rightBarButtonItems *leftbtn = KCUSTOMNAVIGSTION_ALLOC;
    self.navigationItem.leftBarButtonItem = [leftbtn setBarButtonItemsImageName:@"fanhui.png" frame:KLeftBarButtonItemFrame_image target:self SEL:@selector(gotBack)];
    [self layoutSubview];
}

- (void)layoutSubview{
    CGFloat imagesize = 100;
    UIImageView *logoimagev = [[UIImageView alloc]initWithFrame:CGRectMake((KCONTROLLERWith-imagesize)/2, 130, imagesize, imagesize)];
    logoimagev.image = [UIImage imageNamed:@"钱包充值_支付成功.png"];
    [self.view addSubview:logoimagev];
    
    self.statusLabel = [UILabel initWithFrame:CGRectMake(0, KVIEW_Y(logoimagev)+20, KCONTROLLERWith, 30) text:@"交易成功 " font:15 textAlignment:NSTextAlignmentCenter texcolor:[df colorWithHexString:@"333333" alpha:1] backgroundColor:nil];
    [self.view addSubview:self.statusLabel];
    
    UILabel *titleLabel = [UILabel initWithFrame:CGRectMake(0, KVIEW_Y(self.statusLabel)+50, KCONTROLLERWith, 20) text:@"交易金额" font:14 textAlignment:NSTextAlignmentCenter texcolor:[df colorWithHexString:@"66666" alpha:1] backgroundColor:nil];
    [self.view addSubview:titleLabel];
    
    self.moneyLabel = [UILabel initWithFrame:CGRectMake(0, KVIEW_Y(titleLabel)+20, KCONTROLLERWith, 50) text:@"$234878.00" font:36 textAlignment:NSTextAlignmentCenter texcolor:[df colorWithHexString:@"333333" alpha:1] backgroundColor:nil];
    [self.view addSubview:self.moneyLabel];
    
    UIButton *tijiaobutton = [UIButton buttonWithType:UIButtonTypeCustom];
    tijiaobutton.frame = CGRectMake(25, KVIEW_Y(self.moneyLabel)+120, KCONTROLLERWith-40, 50);
    [tijiaobutton addTarget:self action:@selector(tijiao) forControlEvents:UIControlEventTouchUpInside];
    [df layerWithView:tijiaobutton radius:25 width:0 color:nil];
    tijiaobutton.backgroundColor = KZhuTiRGB;
    [tijiaobutton setTitleColor:RGBACOLOR(51, 51, 51, 1) forState:UIControlStateNormal];
    [tijiaobutton setTitle:@"完成" forState:UIControlStateNormal];
    [self.view addSubview:tijiaobutton];
}

- (void)tijiao{
    [self.navigationController popToRootViewControllerAnimated:YES];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
